Optimal. Leaf size=185 \[ -\frac {x^4 \left (A b-2 a B-(b B-2 A c) x^2\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {a \left (b^2 B-6 A b c+8 a B c\right )+\left (b^3 B-4 A b^2 c+2 a b B c+4 a A c^2\right ) x^2}{4 c \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )}+\frac {\left (3 a b B-A \left (b^2+2 a c\right )\right ) \tanh ^{-1}\left (\frac {b+2 c x^2}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{5/2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.17, antiderivative size = 185, normalized size of antiderivative = 1.00, number of steps
used = 5, number of rules used = 5, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {1265, 834, 791,
632, 212} \begin {gather*} \frac {\left (3 a b B-A \left (2 a c+b^2\right )\right ) \tanh ^{-1}\left (\frac {b+2 c x^2}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{5/2}}-\frac {x^4 \left (-2 a B-\left (x^2 (b B-2 A c)\right )+A b\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {a \left (8 a B c-6 A b c+b^2 B\right )+x^2 \left (4 a A c^2+2 a b B c-4 A b^2 c+b^3 B\right )}{4 c \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 212
Rule 632
Rule 791
Rule 834
Rule 1265
Rubi steps
\begin {align*} \int \frac {x^5 \left (A+B x^2\right )}{\left (a+b x^2+c x^4\right )^3} \, dx &=\frac {1}{2} \text {Subst}\left (\int \frac {x^2 (A+B x)}{\left (a+b x+c x^2\right )^3} \, dx,x,x^2\right )\\ &=-\frac {x^4 \left (A b-2 a B-(b B-2 A c) x^2\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {\text {Subst}\left (\int \frac {x (-2 (A b-2 a B)-(b B-2 A c) x)}{\left (a+b x+c x^2\right )^2} \, dx,x,x^2\right )}{4 \left (b^2-4 a c\right )}\\ &=-\frac {x^4 \left (A b-2 a B-(b B-2 A c) x^2\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {a \left (b^2 B-6 A b c+8 a B c\right )+\left (b^3 B-4 A b^2 c+2 a b B c+4 a A c^2\right ) x^2}{4 c \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )}-\frac {\left (3 a b B-A \left (b^2+2 a c\right )\right ) \text {Subst}\left (\int \frac {1}{a+b x+c x^2} \, dx,x,x^2\right )}{2 \left (b^2-4 a c\right )^2}\\ &=-\frac {x^4 \left (A b-2 a B-(b B-2 A c) x^2\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {a \left (b^2 B-6 A b c+8 a B c\right )+\left (b^3 B-4 A b^2 c+2 a b B c+4 a A c^2\right ) x^2}{4 c \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )}+\frac {\left (3 a b B-A \left (b^2+2 a c\right )\right ) \text {Subst}\left (\int \frac {1}{b^2-4 a c-x^2} \, dx,x,b+2 c x^2\right )}{\left (b^2-4 a c\right )^2}\\ &=-\frac {x^4 \left (A b-2 a B-(b B-2 A c) x^2\right )}{4 \left (b^2-4 a c\right ) \left (a+b x^2+c x^4\right )^2}-\frac {a \left (b^2 B-6 A b c+8 a B c\right )+\left (b^3 B-4 A b^2 c+2 a b B c+4 a A c^2\right ) x^2}{4 c \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )}+\frac {\left (3 a b B-A \left (b^2+2 a c\right )\right ) \tanh ^{-1}\left (\frac {b+2 c x^2}{\sqrt {b^2-4 a c}}\right )}{\left (b^2-4 a c\right )^{5/2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.17, size = 233, normalized size = 1.26 \begin {gather*} \frac {1}{4} \left (\frac {-b^4 B+A b^3 c+2 a b c^2 \left (A-3 B x^2\right )+4 a c^2 \left (-4 a B+A c x^2\right )+b^2 c \left (5 a B+2 A c x^2\right )}{c^2 \left (b^2-4 a c\right )^2 \left (a+b x^2+c x^4\right )}+\frac {2 a^2 B c+b^2 (-b B+A c) x^2+a \left (-b^2 B-2 A c^2 x^2+b c \left (A+3 B x^2\right )\right )}{c^2 \left (-b^2+4 a c\right ) \left (a+b x^2+c x^4\right )^2}+\frac {4 \left (-3 a b B+A \left (b^2+2 a c\right )\right ) \tan ^{-1}\left (\frac {b+2 c x^2}{\sqrt {-b^2+4 a c}}\right )}{\left (-b^2+4 a c\right )^{5/2}}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.07, size = 303, normalized size = 1.64
method | result | size |
default | \(\frac {\frac {c \left (2 a c A +A \,b^{2}-3 a b B \right ) x^{6}}{16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}}+\frac {\left (6 A a b \,c^{2}+3 A \,b^{3} c -16 a^{2} B \,c^{2}-a \,b^{2} B c -b^{4} B \right ) x^{4}}{2 c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}-\frac {a \left (2 c^{2} a A -5 A \,b^{2} c +5 a b B c +b^{3} B \right ) x^{2}}{c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}+\frac {a^{2} \left (6 b c A -8 a c B -b^{2} B \right )}{2 c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}}{2 \left (c \,x^{4}+b \,x^{2}+a \right )^{2}}+\frac {\left (2 a c A +A \,b^{2}-3 a b B \right ) \arctan \left (\frac {2 c \,x^{2}+b}{\sqrt {4 a c -b^{2}}}\right )}{\left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right ) \sqrt {4 a c -b^{2}}}\) | \(303\) |
risch | \(\frac {\frac {c \left (2 a c A +A \,b^{2}-3 a b B \right ) x^{6}}{32 a^{2} c^{2}-16 a \,b^{2} c +2 b^{4}}+\frac {\left (6 A a b \,c^{2}+3 A \,b^{3} c -16 a^{2} B \,c^{2}-a \,b^{2} B c -b^{4} B \right ) x^{4}}{4 c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}-\frac {a \left (2 c^{2} a A -5 A \,b^{2} c +5 a b B c +b^{3} B \right ) x^{2}}{2 c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}+\frac {a^{2} \left (6 b c A -8 a c B -b^{2} B \right )}{4 c \left (16 a^{2} c^{2}-8 a \,b^{2} c +b^{4}\right )}}{\left (c \,x^{4}+b \,x^{2}+a \right )^{2}}-\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}-16 a^{2} b \,c^{2}+8 a \,b^{3} c -b^{5}\right ) x^{2}-32 a^{3} c^{2}+16 a^{2} b^{2} c -2 b^{4} a \right ) a c A}{\left (-4 a c +b^{2}\right )^{\frac {5}{2}}}-\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}-16 a^{2} b \,c^{2}+8 a \,b^{3} c -b^{5}\right ) x^{2}-32 a^{3} c^{2}+16 a^{2} b^{2} c -2 b^{4} a \right ) A \,b^{2}}{2 \left (-4 a c +b^{2}\right )^{\frac {5}{2}}}+\frac {3 \ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}-16 a^{2} b \,c^{2}+8 a \,b^{3} c -b^{5}\right ) x^{2}-32 a^{3} c^{2}+16 a^{2} b^{2} c -2 b^{4} a \right ) a b B}{2 \left (-4 a c +b^{2}\right )^{\frac {5}{2}}}+\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}+16 a^{2} b \,c^{2}-8 a \,b^{3} c +b^{5}\right ) x^{2}+32 a^{3} c^{2}-16 a^{2} b^{2} c +2 b^{4} a \right ) a c A}{\left (-4 a c +b^{2}\right )^{\frac {5}{2}}}+\frac {\ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}+16 a^{2} b \,c^{2}-8 a \,b^{3} c +b^{5}\right ) x^{2}+32 a^{3} c^{2}-16 a^{2} b^{2} c +2 b^{4} a \right ) A \,b^{2}}{2 \left (-4 a c +b^{2}\right )^{\frac {5}{2}}}-\frac {3 \ln \left (\left (\left (-4 a c +b^{2}\right )^{\frac {5}{2}}+16 a^{2} b \,c^{2}-8 a \,b^{3} c +b^{5}\right ) x^{2}+32 a^{3} c^{2}-16 a^{2} b^{2} c +2 b^{4} a \right ) a b B}{2 \left (-4 a c +b^{2}\right )^{\frac {5}{2}}}\) | \(682\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: ValueError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] Leaf count of result is larger than twice the leaf count of optimal. 672 vs.
\(2 (177) = 354\).
time = 0.40, size = 1369, normalized size = 7.40 \begin {gather*} \left [-\frac {B a^{2} b^{4} + 2 \, {\left (8 \, A a^{2} c^{4} - 2 \, {\left (6 \, B a^{2} b - A a b^{2}\right )} c^{3} + {\left (3 \, B a b^{3} - A b^{4}\right )} c^{2}\right )} x^{6} + {\left (B b^{6} - 8 \, {\left (8 \, B a^{3} - 3 \, A a^{2} b\right )} c^{3} + 6 \, {\left (2 \, B a^{2} b^{2} + A a b^{3}\right )} c^{2} - 3 \, {\left (B a b^{4} + A b^{5}\right )} c\right )} x^{4} - 8 \, {\left (4 \, B a^{4} - 3 \, A a^{3} b\right )} c^{2} + 2 \, {\left (B a b^{5} - 8 \, A a^{3} c^{3} - 2 \, {\left (10 \, B a^{3} b - 11 \, A a^{2} b^{2}\right )} c^{2} + {\left (B a^{2} b^{3} - 5 \, A a b^{4}\right )} c\right )} x^{2} - 2 \, {\left ({\left (2 \, A a c^{4} - {\left (3 \, B a b - A b^{2}\right )} c^{3}\right )} x^{8} + 2 \, {\left (2 \, A a b c^{3} - {\left (3 \, B a b^{2} - A b^{3}\right )} c^{2}\right )} x^{6} + 2 \, A a^{3} c^{2} + {\left (4 \, A a^{2} c^{3} - 2 \, {\left (3 \, B a^{2} b - 2 \, A a b^{2}\right )} c^{2} - {\left (3 \, B a b^{3} - A b^{4}\right )} c\right )} x^{4} + 2 \, {\left (2 \, A a^{2} b c^{2} - {\left (3 \, B a^{2} b^{2} - A a b^{3}\right )} c\right )} x^{2} - {\left (3 \, B a^{3} b - A a^{2} b^{2}\right )} c\right )} \sqrt {b^{2} - 4 \, a c} \log \left (\frac {2 \, c^{2} x^{4} + 2 \, b c x^{2} + b^{2} - 2 \, a c - {\left (2 \, c x^{2} + b\right )} \sqrt {b^{2} - 4 \, a c}}{c x^{4} + b x^{2} + a}\right ) + 2 \, {\left (2 \, B a^{3} b^{2} - 3 \, A a^{2} b^{3}\right )} c}{4 \, {\left (a^{2} b^{6} c - 12 \, a^{3} b^{4} c^{2} + 48 \, a^{4} b^{2} c^{3} - 64 \, a^{5} c^{4} + {\left (b^{6} c^{3} - 12 \, a b^{4} c^{4} + 48 \, a^{2} b^{2} c^{5} - 64 \, a^{3} c^{6}\right )} x^{8} + 2 \, {\left (b^{7} c^{2} - 12 \, a b^{5} c^{3} + 48 \, a^{2} b^{3} c^{4} - 64 \, a^{3} b c^{5}\right )} x^{6} + {\left (b^{8} c - 10 \, a b^{6} c^{2} + 24 \, a^{2} b^{4} c^{3} + 32 \, a^{3} b^{2} c^{4} - 128 \, a^{4} c^{5}\right )} x^{4} + 2 \, {\left (a b^{7} c - 12 \, a^{2} b^{5} c^{2} + 48 \, a^{3} b^{3} c^{3} - 64 \, a^{4} b c^{4}\right )} x^{2}\right )}}, -\frac {B a^{2} b^{4} + 2 \, {\left (8 \, A a^{2} c^{4} - 2 \, {\left (6 \, B a^{2} b - A a b^{2}\right )} c^{3} + {\left (3 \, B a b^{3} - A b^{4}\right )} c^{2}\right )} x^{6} + {\left (B b^{6} - 8 \, {\left (8 \, B a^{3} - 3 \, A a^{2} b\right )} c^{3} + 6 \, {\left (2 \, B a^{2} b^{2} + A a b^{3}\right )} c^{2} - 3 \, {\left (B a b^{4} + A b^{5}\right )} c\right )} x^{4} - 8 \, {\left (4 \, B a^{4} - 3 \, A a^{3} b\right )} c^{2} + 2 \, {\left (B a b^{5} - 8 \, A a^{3} c^{3} - 2 \, {\left (10 \, B a^{3} b - 11 \, A a^{2} b^{2}\right )} c^{2} + {\left (B a^{2} b^{3} - 5 \, A a b^{4}\right )} c\right )} x^{2} + 4 \, {\left ({\left (2 \, A a c^{4} - {\left (3 \, B a b - A b^{2}\right )} c^{3}\right )} x^{8} + 2 \, {\left (2 \, A a b c^{3} - {\left (3 \, B a b^{2} - A b^{3}\right )} c^{2}\right )} x^{6} + 2 \, A a^{3} c^{2} + {\left (4 \, A a^{2} c^{3} - 2 \, {\left (3 \, B a^{2} b - 2 \, A a b^{2}\right )} c^{2} - {\left (3 \, B a b^{3} - A b^{4}\right )} c\right )} x^{4} + 2 \, {\left (2 \, A a^{2} b c^{2} - {\left (3 \, B a^{2} b^{2} - A a b^{3}\right )} c\right )} x^{2} - {\left (3 \, B a^{3} b - A a^{2} b^{2}\right )} c\right )} \sqrt {-b^{2} + 4 \, a c} \arctan \left (-\frac {{\left (2 \, c x^{2} + b\right )} \sqrt {-b^{2} + 4 \, a c}}{b^{2} - 4 \, a c}\right ) + 2 \, {\left (2 \, B a^{3} b^{2} - 3 \, A a^{2} b^{3}\right )} c}{4 \, {\left (a^{2} b^{6} c - 12 \, a^{3} b^{4} c^{2} + 48 \, a^{4} b^{2} c^{3} - 64 \, a^{5} c^{4} + {\left (b^{6} c^{3} - 12 \, a b^{4} c^{4} + 48 \, a^{2} b^{2} c^{5} - 64 \, a^{3} c^{6}\right )} x^{8} + 2 \, {\left (b^{7} c^{2} - 12 \, a b^{5} c^{3} + 48 \, a^{2} b^{3} c^{4} - 64 \, a^{3} b c^{5}\right )} x^{6} + {\left (b^{8} c - 10 \, a b^{6} c^{2} + 24 \, a^{2} b^{4} c^{3} + 32 \, a^{3} b^{2} c^{4} - 128 \, a^{4} c^{5}\right )} x^{4} + 2 \, {\left (a b^{7} c - 12 \, a^{2} b^{5} c^{2} + 48 \, a^{3} b^{3} c^{3} - 64 \, a^{4} b c^{4}\right )} x^{2}\right )}}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 4.39, size = 268, normalized size = 1.45 \begin {gather*} -\frac {{\left (3 \, B a b - A b^{2} - 2 \, A a c\right )} \arctan \left (\frac {2 \, c x^{2} + b}{\sqrt {-b^{2} + 4 \, a c}}\right )}{{\left (b^{4} - 8 \, a b^{2} c + 16 \, a^{2} c^{2}\right )} \sqrt {-b^{2} + 4 \, a c}} - \frac {6 \, B a b c^{2} x^{6} - 2 \, A b^{2} c^{2} x^{6} - 4 \, A a c^{3} x^{6} + B b^{4} x^{4} + B a b^{2} c x^{4} - 3 \, A b^{3} c x^{4} + 16 \, B a^{2} c^{2} x^{4} - 6 \, A a b c^{2} x^{4} + 2 \, B a b^{3} x^{2} + 10 \, B a^{2} b c x^{2} - 10 \, A a b^{2} c x^{2} + 4 \, A a^{2} c^{2} x^{2} + B a^{2} b^{2} + 8 \, B a^{3} c - 6 \, A a^{2} b c}{4 \, {\left (b^{4} c - 8 \, a b^{2} c^{2} + 16 \, a^{2} c^{3}\right )} {\left (c x^{4} + b x^{2} + a\right )}^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 0.68, size = 625, normalized size = 3.38 \begin {gather*} \frac {\mathrm {atan}\left (\frac {\left (x^2\,\left (\frac {\left (A\,b^2\,c^2-3\,B\,a\,b\,c^2+2\,A\,a\,c^3\right )\,\left (A\,b^2-3\,B\,a\,b+2\,A\,a\,c\right )}{a\,{\left (4\,a\,c-b^2\right )}^{9/2}\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}+\frac {b\,{\left (A\,b^2-3\,B\,a\,b+2\,A\,a\,c\right )}^2\,\left (32\,a^2\,b\,c^4-16\,a\,b^3\,c^3+2\,b^5\,c^2\right )}{2\,a\,{\left (4\,a\,c-b^2\right )}^{15/2}\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}\right )+\frac {2\,b\,c^2\,{\left (A\,b^2-3\,B\,a\,b+2\,A\,a\,c\right )}^2}{{\left (4\,a\,c-b^2\right )}^{15/2}}\right )\,\left (b^4\,{\left (4\,a\,c-b^2\right )}^5+16\,a^2\,c^2\,{\left (4\,a\,c-b^2\right )}^5-8\,a\,b^2\,c\,{\left (4\,a\,c-b^2\right )}^5\right )}{8\,A^2\,a^2\,c^4+8\,A^2\,a\,b^2\,c^3+2\,A^2\,b^4\,c^2-24\,A\,B\,a^2\,b\,c^3-12\,A\,B\,a\,b^3\,c^2+18\,B^2\,a^2\,b^2\,c^2}\right )\,\left (A\,b^2-3\,B\,a\,b+2\,A\,a\,c\right )}{{\left (4\,a\,c-b^2\right )}^{5/2}}-\frac {\frac {x^4\,\left (16\,B\,a^2\,c^2+B\,a\,b^2\,c-6\,A\,a\,b\,c^2+B\,b^4-3\,A\,b^3\,c\right )}{4\,c\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}-\frac {c\,x^6\,\left (A\,b^2-3\,B\,a\,b+2\,A\,a\,c\right )}{2\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}+\frac {a\,\left (8\,B\,c\,a^2+B\,a\,b^2-6\,A\,c\,a\,b\right )}{4\,c\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}+\frac {x^2\,\left (5\,B\,a^2\,b\,c+2\,A\,a^2\,c^2+B\,a\,b^3-5\,A\,a\,b^2\,c\right )}{2\,c\,\left (16\,a^2\,c^2-8\,a\,b^2\,c+b^4\right )}}{x^4\,\left (b^2+2\,a\,c\right )+a^2+c^2\,x^8+2\,a\,b\,x^2+2\,b\,c\,x^6} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________